<!-- eslint-disable max-len -->
<template>
    <div id="nav">
        <div class="logo">黑马面经</div>

        <el-menu router default-active="2" class="el-menu-vertical-demo" @open="handleOpen" @close="handleClose"
            background-color="#313a46" text-color="#fff" active-text-color="#ffd04b">
            <el-menu-item index="/info">
                <i class="el-icon-menu"></i>
                <span slot="title">数据看板</span>
            </el-menu-item>
            <el-menu-item index="/look">
                <i class="el-icon-setting"></i>
                <span slot="title">面经管理</span>
            </el-menu-item>

        </el-menu>
    </div>
</template>
<script>
export default {
  methods: {
    handleOpen(key, keyPath) {
      console.log(key, keyPath);
    },
    handleClose(key, keyPath) {
      console.log(key, keyPath);
    },
  },
};
</script>
<style scoped>
#nav {
    width: 240px;
    background-color: #313a46;
    height: 100vh;
}

.logo {
    height: 80px;
    font-size: 30px;
    color: #fff;
    text-align: center;
    line-height: 80px;
}

.el-menu {
    width: 100%;
}
</style>
